//
//  TextFields.m
//  UI02_UILable_UITextField_UIButton_UIImageView
//
//  Created by wyx on 16/3/10.
//  Copyright © 2016年 Apon. All rights reserved.
//

#import "TextFields.h"

@implementation TextFields

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/
- (instancetype)initWithFrame:(CGRect)frame placeHolder:(NSString *)placeHolder {
    self = [super initWithFrame:frame];
    if (self) {
        //占位符
        self.placeholder = placeHolder;
        //调用 config
        [self config];
    }
    return self;
}
- (void)config {
    //配置边框模式
    self.borderStyle = UITextBorderStyleRoundedRect;
    //清除
    self.clearButtonMode = UITextFieldViewModeAlways;
    //更改键盘亮或暗
    self.keyboardAppearance = UIKeyboardAppearanceDark;
    
}
@end
